/* stylelint-disable selector-no-qualifying-type, selector-type-no-unknown */
:root {
  --fab-width: 56px;
  --fab-height: 56px;
  --fab-position: absolute;
  --fab-mini-width: 40px;
  --fab-mini-height: 40px;

  --material-fab-width: 56px;
  --material-fab-height: 56px;
  --material-fab-position: absolute;
  --material-fab-mini-width: 40px;
  --material-fab-mini-height: 40px;
}

/*~
  name: Fab
  category: Fab
  elements: ons-fab
  markup: |
    <button class="fab"><i class="zmdi zmdi-car"></i></button>
    <button class="fab" disabled><i class="zmdi zmdi-car"></i></button>
*/

ons-fab.fab, ons-speed-dial-item.fab, button.fab {
  position: relative;
  display: inline-block;

  /* mixin: reset-box-model */
  box-sizing: border-box;

  /* mixin: reset-base */
  padding: 0;
  margin: 0;
  font: inherit;
  background: transparent;

  /* mixin: reset-font */
  font-family: -apple-system, 'Helvetica Neue', 'Helvetica', 'Arial', 'Lucida Grande', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-weight: var(--font-weight);

  /* mixin: reset-cursor */
  cursor: default;
  user-select: none;

  width: var(--fab-width);
  height: var(--fab-height);
  text-decoration: none;
  font-size: 25px;
  line-height: var(--fab-height);
  letter-spacing: 0;
  color: var(--fab-text-color);
  vertical-align: middle;
  text-align: center;
  background-color: var(--fab-background-color);
  border: 0 solid currentColor;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.12);
  transition: all 0.1s linear;
}

ons-fab.fab:active, ons-speed-dial-item.fab:active, button.fab:active {
  background-color: var(--fab-active-background-color);
  transition: all 0.2s ease;
  box-shadow: 0 0 6px rgba(0, 0, 0, 0.12);
}

ons-fab.fab:focus, ons-speed-dial-item.fab:focus, button.fab:focus {
  outline: 0;
}

ons-fab.fab:disabled,
ons-fab.fab[disabled],
ons-speed-dial-item.fab:disabled,
ons-speed-dial-item.fab[disabled],
button.fab:disabled,
button.fab[disabled] {
  background-color: rgba(0, 0, 0, 0.5); /* color-mod(black alpha(50%)) */

  /* mixin: material-shadow-0 */
  box-shadow: none;

  /* mixin: disabled */
  opacity: 0.3;
  cursor: default;
  pointer-events: none;
}

ons-fab.fab__icon, ons-speed-dial-item.fab__icon, button.fab__icon {
  position: relative;
  overflow: hidden;
  height: 100%;
  width: 100%;
  display: block;
  border-radius: 100%;
  padding: 0;
  z-index: 100;
  line-height: var(--material-fab-height);
}

/*~
  name: Material Fab
  category: Fab
  elements: ons-fab
  markup: |
    <button class="fab fab--material"><i class="zmdi zmdi-car"></i></button>
    <button class="fab fab--material" disabled><i class="zmdi zmdi-car"></i></button>
*/

ons-fab.fab--material, ons-speed-dial-item.fab--material, button.fab--material {

  /* mixin: material-font */
  font-family: 'Roboto', 'Noto', sans-serif;
  -webkit-font-smoothing: antialiased;
  font-weight: var(--material-font-weight);

  width: var(--material-fab-width);
  height: var(--material-fab-height);
  text-decoration: none;
  font-size: 25px;
  line-height: var(--material-fab-height);
  color: var(--material-fab-text-color);
  background-color: var(--material-fab-background-color);

  /* mixin: material-shadow-2 */
  box-shadow:
    0 4px 5px 0 rgba(0, 0, 0, 0.14),
    0 1px 10px 0 rgba(0, 0, 0, 0.12),
    0 2px 4px -1px rgba(0, 0, 0, 0.4);

  transition: all 0.2s ease-in-out;
}

ons-fab.fab--material:active, ons-speed-dial-item.fab--material:active, button.fab--material:active {

  /* mixin: material-shadow-4 */
  box-shadow:
    0 8px 10px 1px rgba(0, 0, 0, 0.14),
    0 3px 14px 2px rgba(0, 0, 0, 0.12),
    0 5px 5px -3px rgba(0, 0, 0, 0.4);

  background-color: var(--material-fab-active-background-color);
  transition: all 0.2s ease;
}

ons-fab.fab--material:focus, ons-speed-dial-item.fab--material:focus, button.fab--material:focus {
  outline: 0;
}

ons-fab.fab--material__icon, ons-speed-dial-item.fab--material__icon, button.fab--material__icon {
  position: relative;
  overflow: hidden;
  height: 100%;
  width: 100%;
  display: block;
  border-radius: 100%;
  padding: 0;
  z-index: 100;
  line-height: var(--material-fab-height);
}

/*~
  name: Fab Mini
  category: Fab
  elements: ons-fab
  markup: |
    <button class="fab fab--mini"><i class="zmdi zmdi-plus"></i></button>
    <button class="fab fab--mini" disabled><i class="zmdi zmdi-plus"></i></button>
*/

/*~
  name: Material Fab Mini
  category: Fab
  elements: ons-fab
  markup: |
    <button class="fab fab--material fab--mini"><i class="zmdi zmdi-plus"></i></button>
    <button class="fab fab--material fab--mini" disabled><i class="zmdi zmdi-plus"></i></button>
*/

ons-fab.fab--mini, ons-speed-dial-item.fab--mini, button.fab--mini {
  width: var(--fab-mini-width);
  height: var(--fab-mini-height);
  line-height: var(--fab-mini-height);
}

ons-fab.fab--mini__icon, ons-speed-dial-item.fab--mini__icon, button.fab--mini__icon {
  line-height: var(--fab-mini-height);
}

ons-fab.speed-dial__item,  ons-speed-dial-item.speed-dial__item,  button.speed-dial__item  {
  position: absolute;
  transform: scale(0);
}

ons-fab.fab--top__right, button.fab--top__right, .speed-dial.fab--top__right {
  top: 20px;
  bottom: auto;
  right: 20px;
  left: auto;
  position: var(--fab-position);
}

ons-fab.fab--bottom__right, button.fab--bottom__right, .speed-dial.fab--bottom__right {
  top: auto;
  bottom: 20px;
  right: 20px;
  left: auto;
  position: var(--fab-position);
}

ons-fab.fab--top__left, button.fab--top__left, .speed-dial.fab--top__left {
  top: 20px;
  bottom: auto;
  right: auto;
  left: 20px;
  position: var(--fab-position);
}

ons-fab.fab--bottom__left, button.fab--bottom__left, .speed-dial.fab--bottom__left {
  top: auto;
  bottom: 20px;
  right: auto;
  left: 20px;
  position: var(--fab-position);
}

ons-fab.fab--top__center, button.fab--top__center, .speed-dial.fab--top__center {
  top: 20px;
  bottom: auto;
  margin-left: -28px;
  left: 50%;
  right: auto;
  position: var(--fab-position);
}

ons-fab.fab--bottom__center, button.fab--bottom__center, .speed-dial.fab--bottom__center {
  top: auto;
  bottom: 20px;
  margin-left: -28px;
  left: 50%;
  right: auto;
  position: var(--fab-position);
}
/* stylelint-enable selector-no-qualifying-type, selector-type-no-unknown */
